let someArray:Array<any> = [1, "string", false];

/*for(let som of someArray){//迭代
    console.log(som);
}

let lists:Array<number> = [4, 5, 6];

for (let i in lists) {//迭代的是对象的 键 的列表
    console.log(i); // "0", "1", "2",
}

for (let i of lists) {//迭代对象的键对应的值
    console.log(i); // "4", "5", "6"
}
*/
let pets:Array<string> = new Set(["Cat", "Dog", "Hamster"]);
pets["species"] = "mammals";
pets["species1"] = "mammals1";

for (let pet in pets) {
    console.log(pet); // "species"
}

for (let pet of pets) {
    console.log(pet); // "Cat", "Dog", "Hamster"
}